import Vue from "vue";
import Vuex from "vuex";
import tags from "./_src/tags";
import app from "./_src/app";
import im from "./_src/im";
import count from "./_src/count";
import getters from "./getters";

Vue.use(Vuex);
// 状态实例
let store;
// 状态配置项
let storeOptions = {
  modules: {
    tags,
    app,
    im,
    count,
  },
  getters,
};

export default () => {
  store = new Vuex.Store(storeOptions);
};

export { store, storeOptions };
